local Class = require('lua.lang.Class')
local LuaClosure = require('lua.vm.LuaClosure')
local Loader = require('lua.vm.Loader')

--- @class LuaLoader : Loader
local LuaLoader = Class {
	__extends = Loader
}

--- @param prototype Prototype
--- @param chunkName string
--- @param env LuaValue
--- @return LuaFunction
function LuaLoader:load(prototype, chunkName, env)
	return LuaClosure:new(prototype, env)
end

return LuaLoader